<template>
  <div>
      <div class="bank">
          <van-icon name="arrow-left" @click="fun()"  class="iconyi"/>
          <van-icon name="share-o"  class="iconer"  @click="showShare = true,funb()"/>
          <van-share-sheet
           v-model="showShare"
           title="分享到"
           :options="options"/>
      </div>
      <div class="box">
<div class="boxl">
    <img src="../../../public/found/wx1.jpg" alt="">
</div>
<div class="boxr">
    <h3>大厂算法面试真题解析32讲</h3>
    <div class="boxrn">谷歌面试官精选100题，跳出题海战术</div>
    <p class="boxrnp">s09g.Google资深工程师</p>
</div>
      </div>
      <div class="boxx">
        <p class="boxxp">共计32节.已更新26节|32人已订阅</p>
      </div>
      <div class="dongtai" ref="dongtairef">
          <p @click="tem='Xiangqing'" class="dongtaiyi">详情</p>
          <p @click="tem='Mulu'" class="dongtaier"><span>目录</span> <van-badge :content="'试读'" /></p>
          <p @click="tem='Liuyan'" class="dongtaier"><span>留言</span> <van-badge :content="0" /></p>
      </div>
           <component :is="tem" ></component>
      <div class="dibu">
<div class="dibul">
<p class="dibup1">币49.00 <span>币68.00</span> </p>
<p class="dibup2">限时优惠</p>
</div>
<div class="dibur">
<div class="diburq" @click="func()">
    <span >立即购买</span>
</div>

</div>
      </div>
  </div>

</template>

<script>
import Xiangqing from"@/components/foundcomp/xiangqing.vue"
import Mulu from"@/components/foundcomp/mulu.vue"
import Liuyan from"@/components/foundcomp/liuyan.vue"


export default {
data(){
    return{
        tem:"Xiangqing",
          showShare: false,
        options: [
        [
          { name: '微信', icon: 'wechat' },
          { name: '朋友圈', icon: 'wechat-moments' },
          { name: '微博', icon: 'weibo' },
          { name: 'QQ', icon: 'qq' },
        ],
        [
          { name: '复制链接', icon: 'link' },
          { name: '分享海报', icon: 'poster' },
          { name: '二维码', icon: 'qrcode' },
          { name: '小程序码', icon: 'weapp-qrcode' },
        ],
      ],
    
    }
},
components:{
    Xiangqing,Mulu,Liuyan
},
methods:{
    fun(){
        this.$router.go(-1)
    },
    func(){
        this.$router.push("/pay")
    }
}
}
</script>

<style scoped>

.box{
   width: 3.45rem;
   height: 1.4rem;
   background-color: #ebeff2;
   margin: auto;
   margin-top: 0.51rem;
   
}
.boxl img{
    width: 1.09rem;
    height: 1.4rem;
    float: left;
}
.boxr{
    width: 2.26rem;
    height: 100%;
    float: right;
    padding-left: 0.2rem;
}
.boxr>.boxrn{
    width: 2rem;
    height: 0.44rem;
    font-size: 0.13rem;
    padding-top: 0.23rem;
}
.boxr>.boxrnp{
    font-size: 0.09rem;
    padding-top: 0.3rem;
}
.boxx{
    width: 3.45rem;
    height: 0.36rem;
    background-color: #ebeff2;
    margin: auto;
    line-height: 0.36rem;
   padding-top: 0.1rem;

}
.boxx>.boxxp{
    font-size: 0.1rem;
}


.dongtai{
    width: 3.45rem;
    height: 0.46rem;
    line-height: 0.46rem;

    margin: auto;
    display: flex;
    justify-content: space-evenly;
    position: sticky;
    top: 0.35rem;
    border-bottom: 1px solid #c0c0c0;
    background-color: white;
   
}
.dongtaier span{
    width: 0.36rem;
height: 0.23rem;
}
.dongtaier{
width: 0.8rem;
height: 0.23rem;

}
.dongtaiyi{
width: 0.36rem;
height: 0.23rem;
}
.van-badge{
   
    background-color: blue;
}
.bank{
    height: 0.51rem;
    width: 3.45rem;
    margin: auto;
    display: flex;
    justify-content: space-between;
    position: fixed;
    top: 0rem;
    background-color: white;
    left: 0.14rem;
}
.iconyi{
   
    font-size: 0.25rem;
    line-height: 0.51rem;
}
.iconer{
    font-size: 0.25rem;
    line-height: 0.51rem;
}
.dibu{
    width: 3.74rem;
    height: 0.55rem;
    background-color: chocolate;
    position: fixed;
    bottom: 0;
    display: flex;
    justify-content: space-between;
    border-top: 0.55rem;
}
.dibul{
    width: 1.15rem;
    height: 0.55rem;
    margin-left: 0.2rem;
}
.dibur{
    width: 1.66rem;
    height: 0.55rem;
    margin-right: 0.2rem;


}
.dibup1{
    font-size: 0.14rem;
    color: #4276fd;
    padding-top: 0.1rem;
    font-weight: bolder;
}
.dibup1 span{
    font-size: 0.11rem;
    text-decoration: line-through;
    color: #c0c0c0;
}
.dibup2{
    width: 0.46rem;
    height: 0.14rem;
    font-size: 0.08rem;
    color: #4276fd;
    border: 1px solid #4276fd;
    margin-top: 0.05rem;
    font-weight: bolder;
    text-align: center;
}
.diburq{
    width: 1.59rem;
    height: 0.41rem;
    background-color: #4276fd;
    border-radius: 20px;
    line-height: 0.41rem;
    color: white;
    text-align: center;
    margin-top: 0.1rem;
}

</style>